<?php
class Postcode extends AppModel {

     var $name = 'Postcode';
     var $validate = array();
         
    function b_fCheckPostCode($the_sz_PostCode)
    {
        $sz_PostCode = $this->find('first',array('fields'=>array('postcode'),'conditions'=>array('Postcode.postcode'=>strtoupper($the_sz_PostCode))));
        if($sz_PostCode)
            return true;
        else
            return false;
        
    }
    
    function a_fGetPostCode($the_sz_PostCode)
    {
        
         return $this->find('first',array('conditions'=>array('PostCode.postcode'=>strtoupper($the_sz_PostCode))));  
    }
    
	function a_fGetAllPostCode()
    {
         return $this->find('all');  
    }
}
?>